﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Abp.Application.Services;
using Abp.Application.Services.Dto;
using AbpLearningDemo.Companies.Dto;

namespace AbpLearningDemo.Companies
{
    public interface ICompanyAppService : IApplicationService
    {
        /// <summary>
        /// 分页查询
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        Task<PagedResultDto<CompanyListDto>> GetCompaniesAsync(GetCompaniesInput input);

        /// <summary>
        /// 单条数据
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        Task<CompanyListDto> GetCompanyAsync(NullableIdDto<Guid> input);

        /// <summary>
        /// 删除数据
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        Task<DeleteCompanyResult> DeleteCompanyAsync(EntityDto<Guid> input);

        /// <summary>
        /// 新增数据
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<SaveCompanyResult> InsertCompanyAsync(CompanyEditDto dto);

        /// <summary>
        /// 编辑数据
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<SaveCompanyResult> UpdateCompanyAsync(CompanyEditDto dto);
    }
}
